package dao;

/**
 * 当前包下所有Dao或Service类的工厂类
 * @author Chigco.Orc
 *
 */
import org.springframework.beans.BeansException;
import org.springframework.context.ApplicationContext;
import org.springframework.context.ApplicationContextAware;

public class DaoFactory implements ApplicationContextAware{
	private static ApplicationContext ctx;
	public void setApplicationContext(ApplicationContext arg0) throws BeansException {
	this.ctx = arg0;
	}
	
	/**
	 * 获取某个Dao的实例
	 * @return
	 */
	/*
	public static UserDao getUserDao(){
		return (UserDao)ctx.getBean("userDao");
	}
	*/
	
}
